import 'package:kkhousekeep/generated/json/base/json_field.dart';
import 'package:kkhousekeep/generated/json/home_visitor_record_entity.g.dart';
import 'dart:convert';

@JsonSerializable()
class HomeVisitorRecordEntity {
	late int code;
	late HomeVisitorRecordObj obj;
	late String msg;

	HomeVisitorRecordEntity();

	factory HomeVisitorRecordEntity.fromJson(Map<String, dynamic> json) => $HomeVisitorRecordEntityFromJson(json);

	Map<String, dynamic> toJson() => $HomeVisitorRecordEntityToJson(this);

	@override
	String toString() {
		return jsonEncode(this);
	}
}

@JsonSerializable()
class HomeVisitorRecordObj {
	late List<HomeVisitorRecordObjList> list;

	HomeVisitorRecordObj();

	factory HomeVisitorRecordObj.fromJson(Map<String, dynamic> json) => $HomeVisitorRecordObjFromJson(json);

	Map<String, dynamic> toJson() => $HomeVisitorRecordObjToJson(this);

	@override
	String toString() {
		return jsonEncode(this);
	}
}

@JsonSerializable()
class HomeVisitorRecordObjList {
	late int id;
	late String room;
	late String owner;
	late String visitor;
	late String phoneNumber;
	late int visitorNum;
	late String visitStartTime;
	late String visitEndTime;
	late String licensePlate;
	late String visitReason;
	late String qrCodeUrl;
	late String createTime;

	HomeVisitorRecordObjList();

	factory HomeVisitorRecordObjList.fromJson(Map<String, dynamic> json) => $HomeVisitorRecordObjListFromJson(json);

	Map<String, dynamic> toJson() => $HomeVisitorRecordObjListToJson(this);

	@override
	String toString() {
		return jsonEncode(this);
	}
}